Audio encoding technologies are widely used to compress or decompress audio signals, such as voice and music. In audio encoding technologies, various techniques have been proposed to increase the compression efficiency, i.e., reduce the number of bits after encoding, which creates a problem with degradation of sound quality after encoding.
Various technologies have been disclosed to prevent the degradation of the sound quality after encoding (see Japanese Laid-open Patent Publication No. 2001-282288). Moreover, high-efficiency advanced audio coding (HE-AAC), which is used in MPEG-2 and offers high compression efficiency while preventing degradation of the sound quality, has been recently used.
A typical HE-AAC encoding apparatus using HE-AAC includes a spectral band replication (SBR) unit that encodes a high frequency component; and an advanced audio coding (AAC) unit that encodes a low frequency component.
More particularly, the HE-AAC encoding apparatus creates high-frequency-component encoded data by encoding the high frequency component using the SBR encoding unit and low-frequency-component encoded data by encoding the low frequency component using the AAC encoding unit. The HE-AAC encoding apparatus then creates an HE-AAC bitstream by multiplexing the created high-frequency-component encoded data and the created low-frequency-component encoded data.
FIG. 12 is a functional block diagram of the configuration of a conventional encoding apparatus. As illustrated in FIG. 12, the encoding apparatus includes an SBR encoder, an AAC encoder, and a bitstream creating unit.
The AAC encoder uses a technology that encodes data in a frequency domain that is obtained by converting input data. The AAC encoder creates the low-frequency-component encoded data from a low-frequency-band signal contained in the input signal. More particularly, the AAC encoder obtains the low-frequency-band input signal by downsampling the input signal, divides the obtained low-frequency-band input signal into segments at fixed intervals, and encodes each of the segments, thereby creating the AAC encoded data.
The SBR encoder performs data compression by compressing data that is required to replicate the high frequency component from the low frequency component contained in the received input signal. More particularly, the SBR encoder creates a segment zone (time/frequency grid) by dividing the input signal into segments with respect to the time axis and the frequency axis depending on the property of the input signal (the magnitude of change in the signal). The SBR encoder then calculates the spectrum power within the created time/frequency grid and data unreplicable from the low frequency component and quantizes them both. After that, the SBR encoder converts data on the difference between quantization values of adjacent grids into a Huffman code and creates the SBR encoded data by encoding the high frequency component contained in the input signal.
The HE-AAC encoding apparatus multiplexes the high-frequency-component encoded data and the low-frequency-component encoded data using both the SBR encoded data that is created by the SBR encoder and the AAC encoded data that is created by the AAC encoder, thereby creating the HE-AAC bitstream.
There is a problem in that the conventional HE-AAC encoding apparatus cannot reduce the number of bits used in the SBR encoding.
With a conventional HE-AAC encoding apparatus, the total number of encoding bits available in the HE-AAC is determined by the bit rate. In other words, the sum of the number of bits available for the AAC encoder and the number of bits available for the SBR encoder is predetermined by the HE-AAC encoding apparatus. Therefore, if the HE-AAC encoding apparatus uses a low bit rate, the total number of available encoding bits is low.
The AAC encoder can appropriately control the quantization error and the number of encoding bits during the encoding. There is a trade off in the AAC encoder with regard to the relationship between the quantization error and the number of encoding bits. In other words, a low number of bits causes an increase in the quantization error and degradation of the sound quality, while a high number of bits causes a decrease in the quantization error and an improvement in the sound quality.
In contrast, with the SBR encoding, there are no specified ways of controlling the number of bits used in the SBR, i.e., the number of encoding bits varies depending on the property of the input signal. In other words, if the number of bits used in the SBR encoding increases, the number of bits available in the AAC encoding decreases, which increases the quantization error in the AAC encoding. As a result, when the conventional HE-AAC encoding apparatus decodes the high-frequency-component encoded data and the low-frequency-component encoded data and outputs the decoded data as voice, degradation of the total quality of the voice occurs.